New Attribute Manager v.5.0
Author: Mike G.
Updates: Kiril Nedelchev
Email: mp3man@internetwork.net
Dedicated site for this contribution: http://downloads.ephing.com
Date: 04/10/03
by Kiril Nedelchev <kikoleppard@hotmail.bg>
August, 1 , 2005 Updated for Attribute Suite v.1.2.3
- added partial multilanguage compatibility and zero prefix for product price and weight
- removed fields for weight and weight prefix
**********************************************************************
Overview--->
I developed this originally for my clients.. who were fed up with the original
OSCommerce attribute management method. This offers a nice attribute manager
screen to select/deselect all of the option values at once.
**********************************************************************
Upgrading Note--->
I've tried to keep most of my programming seperated from the original
OSCommerce files. What this means to you is that when upgrading this
contribution - most of the time you will just replace the new_attribute files
and be done with it.
**********************************************************************
Installation--->
*This contribution works with 2.2MS1 & should work fine with Preview 2.2
*It's always a good idea to make backups before you begin a modification!
1. *Only perform this step if your default language id isn't 1 (Should be 1 by default).
a) open new_attributes_config.php
b) On line 4 change "1" to your language id.
2. *Only perform this step if you have one of the specified contributions installed.
a) Linda McGrath's Sorter/Copier 5.1 with weight
-a1) Open new_attributes_config.php
-a2) On line 11 set $optionSortCopyInstalled = "1"
b) Attributes Mod version 2.02.MS1 by countezero
-b1) Open new_attributes_config.php
-b2) On line 7 set $optionTypeInstalled = "1"
b) Option Type Feature v1-4 by Chandra Roukema
-b1) Open new_attributes_config.php
-b2) On line 14 set $optionTypeTextInstalled = "1"
-b3) On line 17 set $optionTypeTextInstalledID to your PRODUCTS_OPTIONS_VALUE_TEXT_ID
as specified in catalog/includes/config.php
-b4) It is very important that you keep your products_options_values_to_products_options
table up to date as indicated in Chandra's README.html. If you don't have
entries in this table for your options then my contribution won't work.
3. The following files should go in your /admin/ directory:
a) new_attributes.php
b) new_attributes_include.php - updates for zero price prefix
c) new_attributes_change.php
d) new_attributes_select.php
e) new_attributes_functions.php - updates for zero price and add a function for Single Attribute Manager
f) new_attributes_config.php
in your admin/includes/languages/english put the file
g) new_attribute_manager.php
4. You will need to edit the OSCommerce file admin/includes/boxes/catalog.php:
a) find this line: '<a href="' . tep_href_link(FILENAME_CATEGORIES, '', 'NONSSL') . '" class="menuBoxContentLink">' . BOX_CATALOG_CATEGORIES_PRODUCTS . '</a><br>' .
b) paste this on the line below it: '<a href="' . tep_href_link('new_attributes.php', '', 'NONSSL') . '" class="menuBoxContentLink">*Attribute Manager</a><br>' .
c) Save catalog.php & upload it if you need to.
5. You will need to make a small edit in the OSCommerce file admin/categories.php:
a) I have included categories.php from 2.2MS1 in osc_files/categories.php already modified.
b) If you can't just replace your categories.php with the one I provide, proceed->
b1- In your admin/categories.php find: tep_image_button('button_copy_to.gif', IMAGE_COPY_TO) . '</a>');
b2- replace with: tep_image_button('button_copy_to.gif', IMAGE_COPY_TO) . '</a><a href="./new_attributes.php?action=select¤t_product_id=' . $pInfo->products_id . '&cPath=' . $cPath . '">' . tep_image_button('button_edit_attributes.gif', 'Edit Attributes') . '</A>');
6. Upload the provided images/button_edit_attributes.gif to the directory:
admin/includes/languages/images/buttons/
7. Add this in
admin/includes/filenames.php
//KIKOLEPPARD New attribute manager start
define('FILENAME_NEW_ATTRIBUTE_MANAGER', 'new_attribute_manager.php');
//KIKOLEPPARD New attribute manager start
8. Add this in admin/includes/languages/english.php
// KIKOLEPPARD New attribute manager start
define('BOX_CATALOG_CATEGORIES_ATTRIBUTE_MANAGER', 'Attribute Manager');
// KIKOLEPPARD New attribute manager end
9. For full multilanguage compatibility change this code in new_attributes.php
$adminImages = "includes/languages/english/images/buttons/";
in
$adminImages = "includes/languages/YourLanguage/images/buttons/";
10. VERY IMPORTANT !!!
in catalog/admin/new_attributes_config.php
// Change to your default language ID if it differs. English is set by default
$languageFilter = "1";
That's all.
*********************************************************************
How To Use--->
I didn't remove or edit the original attribute manager. After installation
my manager will appear in the navigation menu above "Products Attributes"
and will be listed as "*Attribute Manager".
*Added "edit attributes" button to the categories/product screen.
You add Options & Option Values using the original OS Commerce Attribute
Management, but use my manager to edit products.
**********************************************************************
Future Plans--->
I am going to combine the attribute management into one page.. using
my system for editing products, and probably the original OS Commerce
system for adding Options & Values.
Compatibility with other contributions continues.. suggestions welcomed.
**********************************************************************
Comments--->
Please send me some feedback.. I don't care if you are criticizing
my programming or letting me know how my little contribution helped
you..etc. It's all welcome =)
You can also email me if you have trouble getting it set up...
although, I feel I've kept it very simple.
email: mp3man@internetwork.net
Go to Step b.1.2 - Single Option - Attribute manager v.1.0